package com.woniuxy.threeproject.end_water_project_user.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.woniuxy.threeproject.end_water_project_user.domain.PaymentDetail;
import com.woniuxy.threeproject.end_water_project_user.dao.PaymentDetailMapper;
import com.woniuxy.threeproject.end_water_project_user.service.IPaymentDetailService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * <p>
 * 费用明细表 服务实现类
 * </p>
 *
 * @author Lucas
 * @since 2021-08-25
 */
@Service
public class PaymentDetailServiceImpl extends ServiceImpl<PaymentDetailMapper, PaymentDetail> implements IPaymentDetailService {
@Resource
public PaymentDetailMapper paymentDetailMapper;
    @Override
    public int add(PaymentDetail p) {
        int i = paymentDetailMapper.insert(p);
        return i;
    }
//    @Override
//    public PaymentDetail getLateFeeAndPrice(Integer userId) {
//        QueryWrapper<PaymentDetail> qw = new QueryWrapper<>();
//        qw.eq("user_id",userId);
//        PaymentDetail py = paymentDetailMapper.selectOne(qw);
//        return py;
//    }
}
